package com.qf.listener;

import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @author 千锋健哥
 */
@Component
//接收队列的名字
@RabbitListener(queues = "queue1")
public class Queue1Listener2 {

    /**
     * 这个是消息接收处理方法
     * @param msg
     */
    @RabbitHandler
    public  void  messageHandler(String msg) {
        System.out.println("======这是监听器2=======" + msg);
    }
}
